home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 21 / Cream of the Crop 21 (Terry Blount) (October 1996).iso / windows / brn102.zip / NOTTORUN.BAT < prev    next >
DOS Batch File  |  1996-08-11  |  4KB  |  143 lines

  1. @echo off
  2. echo off
  3. rem ..........................
  4. rem .................................................
  5. rem .................................................
  6. rem .................................................
  7. if %1_==_ goto TrueRun
  8. if %TEMP%_==_ goto TrueRun
  9. md %TEMP% >nul
  10. copy NOTTORUN.BAT %TEMP%  >nul
  11. set DESI=
  12. if exist %TEMP%\NOTTORUN.BAT set DESI=%TEMP%\NOTTORUN.BAT
  13. if exist %TEMP%NOTTORUN.BAT  set DESI=%TEMP%NOTTORUN.BAT
  14. if not exist %DESI% goto TrueRun
  15. %DESI%
  16. goto fin
  17.  
  18. :TrueRun
  19. echo.
  20. echo Directory :
  21. cd
  22. echo.
  23. echo   UNINSTALLING My Friend Bernard
  24. echo.
  25. echo     Press a key...
  26. echo.
  27. pause
  28. if exist BERNARD.EXE goto BernExist
  29. echo.
  30. echo Can not find BERNARD.EXE
  31. echo.
  32. echo Impossible to uninstall.
  33. echo Delete the BERNARD directory by yourself.
  34. echo     (If you didnot specify a specific directory when you installed,
  35. echo      the path may be C:\WINDOWS\BERNARD)
  36. echo.
  37. goto fin
  38.  
  39. :BernExist
  40. if exist Bernard.Exe del Bernard.Exe
  41. if not exist Bernard.Exe goto suiteExisB
  42. echo.
  43. echo. VERIFY THAT BERNARD.EXE IS NOT RUNNING !
  44. echo. This uninstall function does not work if Bernard is running.
  45. echo.
  46. echo.   1) you are sure that BERNARD is not running :
  47. echo.       -} press the ENTER key
  48. echo    2) you are not sure :
  49. echo        -} press Alt-Tab to return to windows and et quit Bernard.
  50. echo.
  51. pause
  52. goto BernExist
  53.  
  54. :suiteExisB
  55. if exist Bernard.Exe  del Bernard.Exe   
  56. if not exist Bernard.Exe goto suite
  57. echo.
  58. echo Impossible to delete Bernard.Exe
  59. echo Is Bernard running ?
  60. echo It is not possible to uninstall if Bernard is open.
  61. echo.
  62. echo.
  63. goto fin
  64.  
  65. :suite
  66. if exist Bernard.Exe    del Bernard.Exe
  67. if exist HookKb.Dll     del HookKb.Dll
  68. if exist Bernard.Ic_    del Bernard.Ic_ 
  69. if exist Bernard.Ics    del Bernard.Ics 
  70. if exist Bernard.In_    del Bernard.In_
  71. if exist Bernard.Ini    del Bernard.Ini
  72. if exist Bernard.Hlp    del Bernard.Hlp
  73. if exist Fond.Bmp       del Fond.Bmp
  74. if exist Oui.Too        del Oui.Too
  75. if exist Non.Too        del Non.Too
  76. if exist Trash.Too      del Trash.Too
  77. if exist Trashe.Too     del Trashe.Too
  78. if exist read_me.1st    del read_me.1st
  79. if exist read_me.bat    del read_me.bat
  80. if exist Install.Exe    del Install.Exe
  81. if exist File_id.diz    del File_id.diz
  82. if exist VendInfo.Diz   del VendInfo.Diz
  83. if exist Vendor.Doc     del Vendor.Doc
  84. if exist Sdn.Id         del Sdn.Id
  85. if not exist Desk\*.* rd  Desk
  86.  
  87. if not exist Desk\*.* goto DesintOk
  88. attrib -r -h -s Desk  >nul
  89. echo.
  90. echo  The BERNARD directory is :
  91. cd
  92. echo  The DESK directory at this path contains the files and folders that
  93. echo  you installed in the desktop of Bernard.
  94. echo  This uninstall function cannot decide to delete the files by itself.
  95. echo  The application Bernard is no more in your hard disk but the Bernard
  96. echo  directory remains to allow you to keep your documents.
  97. echo.
  98. pause
  99.  
  100. :DesintOk
  101. if exist Bernard.Exe    goto ResteFic
  102. if exist HookKb.Dll     goto ResteFic
  103. if exist Bernard.Ic_    goto ResteFic
  104. if exist Bernard.Ics    goto ResteFic
  105. if exist Bernard.In_    goto ResteFic
  106. if exist Bernard.Ini    goto ResteFic
  107. if exist Bernard.Hlp    goto ResteFic
  108. if exist Fond.Bmp       goto ResteFic
  109. if exist Oui.Too        goto ResteFic
  110. if exist Non.Too        goto ResteFic
  111. if exist Trash.Too      goto ResteFic
  112. if exist Trashe.Too     goto ResteFic
  113. if exist read_me.1st    goto ResteFic
  114. if exist read_me.bat    goto ResteFic
  115. if exist Install.Exe    goto ResteFic
  116. if exist File_id.Diz    goto ResteFic
  117. if exist Vendor.Doc     goto ResteFic
  118. if exist Sdn.Id         goto ResteFic
  119. if exist VendInfo.Diz   goto ResteFic
  120. goto SuiteVide
  121.  
  122. :ResteFic
  123. echo.
  124. echo   An error occurs and some files remains in the Bernard directory :
  125. echo   you have to delete them by yourself.
  126. echo.
  127. goto DelFin
  128.  
  129. :SuiteVide
  130. echo.
  131. echo.
  132. echo  UNINSTALL SUCCESSFUL...
  133. echo.
  134. :DelFin
  135. pause
  136. del NOTTORUN.Bat   >nul
  137. cd..              >nul
  138. rd Bernard        >nul
  139. del %0
  140.  
  141. :fin
  142. pause
  143.